|
xportethse 2.2.1
|
API for configuring and manipulating XPort ETH SE Click driver. More...
Topics | |
| XPort ETH SE Device Settings | |
| Settings for registers of XPort ETH SE Click driver. | |
| XPort ETH SE MikroBUS Map | |
| MikroBUS pin mapping of XPort ETH SE Click driver. | |
Functions | |
| void | xportethse_cfg_setup (xportethse_cfg_t *cfg) |
| XPort ETH SE configuration object setup function. | |
| err_t | xportethse_init (xportethse_t *ctx, xportethse_cfg_t *cfg) |
| XPort ETH SE initialization function. | |
| err_t | xportethse_generic_write (xportethse_t *ctx, uint8_t *data_in, uint16_t len) |
| XPort ETH SE data writing function. | |
| err_t | xportethse_generic_read (xportethse_t *ctx, uint8_t *data_out, uint16_t len) |
| XPort ETH SE data reading function. | |
| void | xportethse_send_cmd (xportethse_t *ctx, uint8_t *cmd) |
| XPort ETH SE send cmd function. | |
| void | xportethse_send_enter (xportethse_t *ctx) |
| XPort ETH SE send enter function. | |
| void | xportethse_set_rst_pin (xportethse_t *ctx, uint8_t state) |
| XPort ETH SE set RST pin function. | |
| void | xportethse_set_cts_pin (xportethse_t *ctx, uint8_t state) |
| XPort ETH SE set CTS pin function. | |
| uint8_t | xportethse_get_rts_pin (xportethse_t *ctx) |
| XPort ETH SE get RTS pin function. | |
| uint8_t | xportethse_get_dtr_pin (xportethse_t *ctx) |
| XPort ETH SE get DTR pin function. | |
| void | xportethse_reset_device (xportethse_t *ctx) |
| XPort ETH SE reset device function. | |
API for configuring and manipulating XPort ETH SE Click driver.
Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.
| void xportethse_cfg_setup | ( | xportethse_cfg_t * | cfg | ) |
XPort ETH SE configuration object setup function.
This function initializes Click configuration structure to initial values.
| [out] | cfg | : Click configuration structure. See xportethse_cfg_t object definition for detailed explanation. |
| err_t xportethse_generic_read | ( | xportethse_t * | ctx, |
| uint8_t * | data_out, | ||
| uint16_t | len ) |
XPort ETH SE data reading function.
This function reads a desired number of data bytes by using UART serial interface.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| [out] | data_out | : Output read data. |
| [in] | len | : Number of bytes to be read. |
>0 - Number of data bytes read, <=0 - Error/Empty Ring buffer. See #err_t definition for detailed explanation. | err_t xportethse_generic_write | ( | xportethse_t * | ctx, |
| uint8_t * | data_in, | ||
| uint16_t | len ) |
XPort ETH SE data writing function.
This function writes a desired number of data bytes by using UART serial interface.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| [in] | data_in | : Data buffer for sending. |
| [in] | len | : Number of bytes for sending. |
>=0 - Success, <0 - Error. See #err_t definition for detailed explanation. | uint8_t xportethse_get_dtr_pin | ( | xportethse_t * | ctx | ) |
XPort ETH SE get DTR pin function.
This function returns the DTR pin logic state.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| uint8_t xportethse_get_rts_pin | ( | xportethse_t * | ctx | ) |
XPort ETH SE get RTS pin function.
This function returns the RTS pin logic state.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| err_t xportethse_init | ( | xportethse_t * | ctx, |
| xportethse_cfg_t * | cfg ) |
XPort ETH SE initialization function.
This function initializes all necessary pins and peripherals used for this Click board.
| [out] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| [in] | cfg | : Click configuration structure. See xportethse_cfg_t object definition for detailed explanation. |
0 - Success, -1 - Error. See #err_t definition for detailed explanation. | void xportethse_reset_device | ( | xportethse_t * | ctx | ) |
XPort ETH SE reset device function.
This function resets device by toggling the RST pin state.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| void xportethse_send_cmd | ( | xportethse_t * | ctx, |
| uint8_t * | cmd ) |
XPort ETH SE send cmd function.
This function sends a command string by using UART serial interface.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| [in] | cmd | : Command string to send. |
| void xportethse_send_enter | ( | xportethse_t * | ctx | ) |
XPort ETH SE send enter function.
This function sends enter (new line) by using UART serial interface.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| void xportethse_set_cts_pin | ( | xportethse_t * | ctx, |
| uint8_t | state ) |
XPort ETH SE set CTS pin function.
This function sets the CTS pin logic state.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| [in] | state | : Pin logic state. |
| void xportethse_set_rst_pin | ( | xportethse_t * | ctx, |
| uint8_t | state ) |
XPort ETH SE set RST pin function.
This function sets the RST pin logic state.
| [in] | ctx | : Click context object. See xportethse_t object definition for detailed explanation. |
| [in] | state | : Pin logic state. |